<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>健康上报</title>
    <script src="js/WebCalendar.js" type="text/javascript"></script>
</head>
<body>
    <div>
        <div>
            你好，
            <span th:if="${session.user == null}">
                <a title="登录" th:href="@{/}">请登录</a>
            </span>
            <span style="color: blue" th:text="${session.user.getUserName()}"></span>
        </div>
        <span style="color: red" th:text="${message}"></span>
        <form th:if="${session.user != null}" th:action="@{/report}">
            <input type="hidden" th:name="reportId" th:value="${session.report.getReportId()}">
            <input type="hidden" th:name="userId" th:value="${session.report.getUserId()}">
            <input type="hidden" th:name="date" th:value="${session.report.getDate()}">
            证件类型：
            <select name="IDType" th:value="${session.report.getIDType()}">
                <option value="居民身份证" th:selected="${session.report.getIDType() == '居民身份证'}">居民身份证</option>
            </select>
            <br>
            证件号码：
            <input type="text" required="required" placeholder="请输入" th:name="IDNumber" th:value="${session.report.getIDNumber()}">
            <br>
            户籍：
            <input type="text" required="required" placeholder="请输入" th:name="RPR" th:value="${session.report.getRPR()}">
            <br>
            手机号码：
            <input type="text" required="required" placeholder="请输入" th:name="phone" th:value="${session.report.getPhone()}">
            <br>
            当前位置：
            <input type="text" required="required" placeholder="请输入" th:name="location" th:value="${session.report.getLocation()}">
            <br>
            身体状况：
            <select name="state" th:value="${session.report.getState()}">
                <option value="良好" th:selected="${session.report.getState() == '良好'}">良好</option>
            </select>
            <br>
            目前健康码状况：
            绿码
            <input type="radio" name="healthColor" th:value="绿码" th:checked="${session.report.getHealthColor() == '绿码'}">
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;黄码
            <input type="radio" name="healthColor" th:value="黄码" th:checked="${session.report.getHealthColor() == '黄码'}">
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;红码
            <input type="radio" name="healthColor" th:value="红码" th:checked="${session.report.getHealthColor() == '红码'}">
            <br>
            目前行程卡状况：
            绿卡
            <input type="radio" name="travelColor" th:value="绿卡" th:checked="${session.report.getTravelColor() == '绿卡'}">
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;黄卡
            <input type="radio" name="travelColor" th:value="黄卡" th:checked="${session.report.getTravelColor() == '黄卡'}">
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;红卡
            <input type="radio" name="travelColor" th:value="红卡" th:checked="${session.report.getTravelColor() == '红卡'}">
            <br>
            目前疫苗接种状况：
            已接种两针
            <input type="radio" name="inoculated" th:value="已接种两针" th:checked="${session.report.getInoculated() == '已接种两针'}">
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;已接种一针
            <input type="radio" name="inoculated" th:value="已接种一针" th:checked="${session.report.getInoculated() == '已接种一针'}">
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;未接种
            <input type="radio" name="inoculated" th:value="未接种" th:checked="${session.report.getInoculated() == '未接种'}">
            <br>
            <input type="submit" value="提交" th:if="${message} == '您今日未上报'">
        </form>
    </div>
</body>
</html>